package com.wisdomstar.wordfilter.config;

import com.wisdomstar.wordfilter.filter.WordContext;
import com.wisdomstar.wordfilter.filter.WordFilter;
import com.wisdomstar.wordfilter.service.WordService;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import javax.annotation.Resource;

/**
 * @author RinMi
 * @since 2023/6/12
 */

@Configuration
public class WordConfig {

    @Resource
    private WordService wordService;

    @Bean
    public WordFilter getWordFilter(){
        WordContext wordContext = new WordContext(wordService);
        return new WordFilter(wordContext);
    }


}
